<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<%@ taglib prefix="s" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags"%>
<jsp:include page="/WEB-INF/views/commons/center_top.jsp"/>
<script type="text/javascript" src="/static/module/commons/public.js"></script>

<div class="contBox clear">
	<div class="col-sm-6 no-padding">
		<div class="widget-box">
			<div class="widget-header header-color-blue">
				<span>单位管理</span>
				<div class="widget-toolbar no-border">
					<div class="btn-group">
						<button class="btn btn-info btn-sm btn-add"><i class='icon-plus-sign bigger-150'></i>添加</button>
						<button class="btn btn-info btn-sm btn-update"><i class='icon-pencil bigger-150'></i>编辑</button>
						<button class="btn btn-info btn-sm btn-delete"><i class='icon-trash bigger-150'></i>刪除</button>
						<button class="btn btn-info btn-sm btn-type"><i class='icon-pencil bigger-150'></i>管理人员类型</button>
					</div>

				</div>
			</div>
			<div class="widget-body overflow">
				<table id="my_tree_grid"></table>
			</div>
		</div>
	</div>
	
 	<div id="jobs_panel" style="display: none" class="col-sm-6 no-padding-right">
 		<div class="widget-box">
			<div class="widget-header header-color-blue">
				<span>人员类型</span>
				<div class="widget-toolbar no-border">
					<div class="btn-group">
						<button class="btn btn-info btn-sm btn-jobs-add"><i class='icon-plus-sign bigger-150'></i>添加</button>
						<button class="btn btn-info btn-sm btn-jobs-update"><i class='icon-pencil bigger-150'></i>编辑</button>
						<button class="btn btn-info btn-sm btn-jobs-delete"><i class='icon-trash bigger-150'></i>刪除</button>
					</div>

				</div>
			</div>
			<div class="widget-body">
				<table id="grid-table"></table>
			</div>
		</div>
  	</div>
 	
 	<div id="dept_panel" style="display: none" class="col-sm-6 no-padding-right">
		<div class="widget-box">
		 	<div class="widget-header header-color-blue">
		 	<span>单位编辑</span>
				<div class="widget-toolbar no-border">
					<div class="btn-group">
						<button class="btn btn-info btn-sm ifshow" onclick="doDeptSave()"  id="roleSave">
							<i class="icon-save bigger-150"></i>
							保存
						</button> 
					</div>
				</div>
			</div>
		 	<div class="widget-body">
		 	<div class="widget-main padding-8">
			<div  class="tree-unselectable clear">
			 	<form name="deptform" id="deptform" class="FormGrid"   >
			 		<input type="hidden"  name="areaId" id="form_areaId" />
					<input type="hidden" name="id" id="form_id" />
					<input type="hidden" id="form_parentId2" />
					<input type="hidden" name="parentId" id="form_parentId" />
					<div class="form-group col-sm-12">
						<label class="col-sm-2 control-label no-padding-right" for="form-field-1"> 单位名称 </label>
						<div class="col-sm-10">
							<input name="name" id="form_name" class="col-xs-10 col-sm-9 required" type="text" >
						</div>
					</div>
					<div class="form-group col-sm-12">
						<label class="col-sm-2 control-label no-padding-right" for="form-field-1"> 单位编码 </label>
						<div class="col-sm-10">
							<input name="code" id="form_code" class="col-xs-10 col-sm-9 required" type="text" >
						</div>
					</div>
					<div class="form-group col-sm-12">
						<label class="col-sm-2 control-label no-padding-right" for="form-field-1"> 上级单位 </label>
						<div class="col-sm-10">
							<div class="input-group col-xs-10 col-sm-9 no-padding"  >
								<input id="parentDeptSelectName" name="" readonly="readonly" type="text" value="" data-msg-required="" class="form-control " style="">
								<span class="input-group-btn" onclick="showParentDeptMenu(); return false;">
									<a id="subjectButton" href="javascript:" class="btn btn-primary btn-sm dropdown-toggle"> <span class="caret"></span></a>
								</span>
								<div id="menuContentParentDept"  class="menuContent " style="display:none; position: absolute; z-index:999">
									<ul id="treeDemoParentDept" class="ztree" style="margin-top:0; "></ul>
								</div>
							</div>
						</div>
					</div>
					<div class="form-group col-sm-12">
						<label class="col-sm-2 control-label no-padding-right" for="form-field-1"> 所属区域 </label>
						<div class="col-sm-10">
							<div class="input-group col-xs-10 col-sm-9 no-padding"  >
								<input id="areaName" name="" readonly="readonly" type="text" value="" data-msg-required="" class="form-control " style="">
								<span class="input-group-btn"  onclick="showAreaMenu(); return false;">
									<a id="subjectButton" href="javascript:" class="btn btn-primary btn-sm dropdown-toggle"> <span class="caret"></span></a>
								</span>
								<div id="menuContentArea" class="menuContent " style="display:none; position: absolute; z-index:999">
									<ul id="treeDemoArea" class="ztree" style="margin-top:0; "></ul>
								</div>
							</div>
						</div>
					</div>
				</form>
			</div>
			</div>
			</div>
		</div>
 	</div>
	 
	<!--添加类型 -->
	<div id="jobinfo" class="jobinfo hide"   >
	<div class="ui-jqdialog-content ui-widget-content" >
		<form name="jobform" id="jobform" class="FormGrid"   style="width:auto;overflow:auto;position:relative;height:auto;">
			<input type="hidden"  name="deptId" class="clear_save" id="form_job_dept" />
			<input type="hidden"  name="id" id="form_job_id" />
			<table id="TblGrid_grid-table" class="EditTable" cellspacing="0" cellpadding="0" border="0">
				<tbody>
					<tr id="FormError" style="display:none">
						<td class="ui-state-error" colspan="2">
						</td>
					</tr> 
					<tr rowpos="1" class="FormData" id="tr_id">
						<td class="CaptionTD"> 人员类型名称 </td>
						<td class="DataTD"> &nbsp;
							<input type="text" name="name" id="form_job_name"  role="textbox" class="form_dict_name FormElement ui-widget-content ui-corner-all required">
						</td>
					</tr>
					<tr rowpos="1" class="FormData" id="tr_id">
						<td class="CaptionTD"> 人员类型编码 </td>
						<td class="DataTD"> &nbsp;
							<input type="text"  name="code" id="form_job_code" role="textbox" class="form_dict_name FormElement ui-widget-content ui-corner-all required">
						</td>
					</tr>
				</tbody>
			</table>
		</form>
		<table border="0" cellspacing="0" cellpadding="0" class="EditTable" id="TblGrid_grid-table_2">
			<tbody>
				<tr> <td colspan="2"> <hr class="ui-widget-content" style="margin:1px"> </td> </tr>
				<tr id="Act_Buttons">
					<td class="EditButton">
						<a href="javascript:doSaveJobs()" id="sData" class="fm-button ui-state-default ui-corner-all fm-button-icon-left btn btn-sm btn-primary">
							<i class="icon-ok"> </i> 提交
						</a>
						<a href="javascript:RM.close()" id="cData" class="fm-button ui-state-default ui-corner-all fm-button-icon-left btn btn-sm">
							<i class="icon-remove"> </i> 取消
						</a>
					</td>
				</tr>
				<tr style="display:none" class="binfo">
					<td class="bottominfo" colspan="2"> </td>
				</tr>
			</tbody>
		</table>
	</div>
	</div>
	
</div>
<script type="text/javascript" src="/static/module/system/dept/index.js"></script>
<jsp:include page="/WEB-INF/views/commons/center_bottom.jsp"/>